package nancal.mp

import nbcp.base.extend.Slice
import org.springframework.context.ApplicationListener
import org.springframework.context.annotation.Configuration
import org.springframework.context.event.ContextRefreshedEvent

/**
 * Created by yuxh on 2018/9/11
 */

@Configuration
open class PzxEntityInit : ApplicationListener<ContextRefreshedEvent> {
    override fun onApplicationEvent(event: ContextRefreshedEvent) {

    }
}


/**
 * 获取Harbor镜像的 名称:版本 部分（去除Host）
 */
val String.imageNameVersion: String
    get() {
        if (!this.contains("/")) return "";
        return this.Slice(this.indexOf("/") + 1);
    }